package com.gwnet.shop.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.gwnet.common.mybatis.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import java.util.Date;

/**
 * 订单支付对象 order_payment
 * 
 * @author ruoyi
 * @date 2024-07-21
 */
public class OrderPayment extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 自增ID */
    private Long id;

    /** 付款用户 */
    private Long userId;

    /** 订单号 */
    private String orderId;

    /** 交易单号 */
    private String tradeNo;

    /** 支付名称 */
    private String paymentTitle;

    /** 支付金额 */
    private Double paymentAmount;

    /** 支付状态  0.待支付 1.已支付 2.已取消 */
    private String status;

    /** 支付类型0正常支付 2 退款 */
    private String paymentType;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date paymentTime;

    /** 退款时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date refundTime;

    /** 备注 */
    private String remark;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setUserId(Long userId) 
    {
        this.userId = userId;
    }

    public Long getUserId() 
    {
        return userId;
    }
    public void setOrderId(String orderId) 
    {
        this.orderId = orderId;
    }

    public String getOrderId() 
    {
        return orderId;
    }
    public void setTradeNo(String tradeNo) 
    {
        this.tradeNo = tradeNo;
    }

    public String getTradeNo() 
    {
        return tradeNo;
    }
    public void setPaymentTitle(String paymentTitle) 
    {
        this.paymentTitle = paymentTitle;
    }

    public String getPaymentTitle() 
    {
        return paymentTitle;
    }

    public Double getPaymentAmount() {
        return paymentAmount;
    }

    public void setPaymentAmount(Double paymentAmount) {
        this.paymentAmount = paymentAmount;
    }

    public void setStatus(String status)
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }

    public String getPaymentType() {
        return paymentType;
    }

    public void setPaymentType(String paymentType) {
        this.paymentType = paymentType;
    }

    public void setPaymentTime(Date paymentTime)
    {
        this.paymentTime = paymentTime;
    }

    public Date getPaymentTime() 
    {
        return paymentTime;
    }
    public void setRefundTime(Date refundTime) 
    {
        this.refundTime = refundTime;
    }

    public Date getRefundTime() 
    {
        return refundTime;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("userId", getUserId())
            .append("orderId", getOrderId())
            .append("tradeNo", getTradeNo())
            .append("paymentTitle", getPaymentTitle())
            .append("paymentAmount", getPaymentAmount())
            .append("status", getStatus())
            .append("paymentType", getPaymentType())
            .append("paymentTime", getPaymentTime())
            .append("refundTime", getRefundTime())
            .toString();
    }
}
